<%-- 
    Document   : Reservation
    Created on : 14 nov. 2012, 09:07:43
    Author     : jeddi
--%>


<%@page import="enterprise.web_jpa_war.entity.Reservation"%>
<%@page import="enterprise.web_jpa_war.entity.Demande"%>
<%@page import="java.util.Map"%>
<%@page import="java.util.Vector"%>
<%@page import="enterprise.web_jpa_war.entity.Oeuvre"%>
<%@page import="enterprise.web_jpa_war.servlet.Fonctions"%>
<%@page contentType="text/html" pageEncoding="UTF-8"%>
<!DOCTYPE html>
<html>
    <head>
        <title>Mediatheque : Accueil</title>
        <meta content="text/html; charset=UTF-8" http-equiv="Content-Type">
        <link type="text/css" rel="Stylesheet" media="screen" href="Css/design.css">
        <link type="text/css" rel="Stylesheet" media="screen" href="Css/bootstrap.min.css">
        <link href="Images/favicon.png" type="image/png" rel="icon">
    </head>
    <body>
        
        <%
        Fonctions f = new Fonctions();
        out.print(f.printNavBar());
        Vector<Reservation> reservList = (Vector<Reservation>) request.getAttribute("reservationList");
        %>
        
        <div class="container-fluid">
            
        <%
        out.print(f.printSideBar());
        %>
            <div class="content">
                <div class="hero-unit">
                    <div class="page-header">
                        <h1 id="titre">Mediatheque : Réservation</h1>
                        <h3>Articles que vous avez réservés</h3>
                    </div>
                    <div class="well bloc_texte">
                        <table id="panierTable">
                            <tr>
                                <th>Titre</th>
                                <th>Auteur</th>
                                <th>Date d'edition</th>
                                <th>Genre</th>
                                <th>Date de réservation</th>
                                <th>Description</th>
                            </tr>
                            <%
                            for(Reservation r : reservList){
                            %>
                            <tr>
                                <td><% out.print(r.getOeuvre().getTitre()); %></td> 
                                <td><% out.print(r.getOeuvre().getAuteur()); %></td> 
                                <td><% out.print(r.getOeuvre().getDateEdition()); %></td>
                                <td><% out.print(r.getOeuvre().getGenre()); %></td> 
                                <td><% out.print(r.getDateReservation()); %></td>
                                <td><% out.print(r.getOeuvre().getDescription()); %></td>
                            </tr>
                            <%
                            }
                            %>
                        </table>
                        <a href='index.jsp'><strong>Retour au menu principal</strong></a>
                    </div>
                </div>
            </div>
        </div>
    </body>
</html>